package com.huluobo.a2204monthdemo.adapter

import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.huluobo.a2204monthdemo.R
import com.huluobo.a2204monthdemo.utils.ImageUtils
import com.huluobo.base.bean.HomeNavBean

/**
 *  Created by LC on 2024/8/8.
 */
class NavAdapter(list: MutableList<HomeNavBean>) :
    BaseQuickAdapter<HomeNavBean, BaseViewHolder>(R.layout.item_nav, list) {
    override fun convert(helper: BaseViewHolder, item: HomeNavBean) {
        ImageUtils.loadImage(context, item.category_icon!!, helper.getView(R.id.item_nav_icon))
        helper.setText(R.id.item_nav_name_tv, item.category_name)
    }
}